package org.dangran.service.impl;

import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.kafka.support.Acknowledgment;
import org.springframework.stereotype.Service;

@Service
public class KafkaServiceImpl {

//    @KafkaListener(topics = "testTopic",groupId = "testTopic")
//    public void receiveKafkaMsg(ConsumerRecord<String,Object> record, Acknowledgment acknowledgment){
//        System.out.println("value:"+record.value());
//        //手动提交偏移量
//        acknowledgment.acknowledge();
//    }

}
